#include "qbooblecontrol.h"

QBoobleControl::QBoobleControl(QWidget *parent) :
    QWidget(parent)
{
    m_booble = new BoobleWidget(this);
    m_booble->setGeometry(0,0, m_booble->width(), m_booble->height());
    setFixedSize(m_booble->width(), m_booble->height());
    m_hlanim = new HighlightAnimation(m_booble);
    m_boomanim = new QBoomAnimation(m_booble);
    setAttribute(Qt::WA_TranslucentBackground);
}

void QBoobleControl::boom()
{
    m_boomanim->start();
    connect(m_boomanim, SIGNAL(finished()), this, SLOT(destroyBooble()));
}
void QBoobleControl::highlight()
{
    m_hlanim->start();
}
